home *** CD-ROM | disk | FTP | other *** search
Text File | 1996-04-25 | 2.9 KB | 111 lines | [TEXT/MPS ] |
- //========================================================================================
- //
- // File: FWLnkCmd.h
- // Release Version: $ ODF 1 $
- //
- // Copyright: (c) 1993 - 1996 by Apple Computer, Inc., all rights reserved.
- //
- //========================================================================================
-
- #ifndef FWLNKCMD_H
- #define FWLNKCMD_H
-
- #ifndef FWCMD_H
- #include "FWCmd.h"
- #endif
-
- // ----- OpenDoc Includes -----
-
- #ifndef FWODTYPS_H
- #include "FWODTyps.h"
- #endif
-
- //========================================================================================
- // Forward Declarations
- //========================================================================================
-
- class FW_CPart;
- class FW_CFrame;
- class FW_CLinkSource;
- class FW_CLinkManager;
- class FW_CLinkDestination;
- class ODLinkSource;
-
- //========================================================================================
- // FW_CPrivCreateLinkSourceCommand - create a link at the source (undoable)
- //========================================================================================
-
- class FW_CPrivCreateLinkSourceCommand : public FW_CCommand
- {
- public:
- FW_DECLARE_AUTO(FW_CPrivCreateLinkSourceCommand)
-
- //----- Constructors/Destructor
- public:
- FW_CPrivCreateLinkSourceCommand(Environment* ev,
- FW_CFrame* frame,
- FW_CLinkManager* linkMgr,
- FW_CLinkSource* pendingLink);
-
- virtual ~FW_CPrivCreateLinkSourceCommand();
-
- //----- Inherited API
- public:
- virtual void DoIt(Environment* ev);
- virtual void UndoIt(Environment* ev);
- virtual void RedoIt(Environment* ev);
- virtual void CommitUndone(Environment* ev);
-
- //----- Command-specific Methods
- public:
- ODLinkSource* GetODLinkSource(Environment* ev);
-
- //----- Data Members
- private:
- FW_CLinkManager* fLinkMgr;
- FW_CLinkSource* fLinkSource;
- };
-
- //========================================================================================
- // FW_CPrivCreateLinkCommand - create a link at the destination (undoable)
- //========================================================================================
-
- class FW_CPrivCreateLinkCommand : public FW_CCommand
- {
- public:
- FW_DECLARE_AUTO(FW_CPrivCreateLinkCommand)
-
- //----- Constructors/Destructor
- public:
- FW_CPrivCreateLinkCommand(Environment* ev,
- FW_CFrame* frame,
- FW_CLinkManager* linkMgr,
- FW_Boolean fromClipboard);
-
- virtual ~FW_CPrivCreateLinkCommand();
-
- //----- Inherited API
- public:
- virtual void DoIt(Environment* ev);
- virtual void UndoIt(Environment* ev);
- virtual void RedoIt(Environment* ev);
- virtual void CommitUndone(Environment* ev);
-
- //----- Command-specific Methods
- public:
- void SetLink(Environment* ev, FW_CLinkDestination* link);
-
- //----- Data Members
- private:
- FW_CLinkManager* fLinkMgr;
- FW_CLinkDestination* fLink;
- };
-
- //---------------------------------------------------------------------------------
- inline void FW_CPrivCreateLinkCommand::SetLink(Environment*, FW_CLinkDestination* link)
- {
- fLink = link;
- }
-
- #endif
-